package com.sharp.kernel.mybatis.repository;

import com.sharp.kernel.mybatis.mapper.MysqlBaseMapper;
import com.sharp.kernel.mybatis.repository.inf.MySqlInsertRepository;

import java.util.List;

/**
 * Title: BaseMysqlRepository
 * Description: Copyright: Copyright (c) 2019 Company: BHFAE
 *
 * @author Sharp
 * @date 2022/6/8 16:24
 */
public class BaseMysqlRepository<T, K extends MysqlBaseMapper<T>> extends BaseSqlRepository<T, K> implements MySqlInsertRepository<T> {

    @Override
    public int insertBatch(List<T> entityList) {
        return getDao().insertList(entityList);
    }

    @Override
    public int insertBatchWithPrimaryKey(List<T> entityList) {
        return getDao().insertListWithPrimaryKey(entityList);
    }
}
